import Vue from 'vue'
import Router from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
import Teacher from '../components/often/teacher'
import Student from '../components/often/student'
import Dashboard from '../components/often/Dashboard'
import Notice from '../components/often/Notice'
import SysConfig from '../components/often/sysCofig'
import JudSer from '../components/often/JudgeServer'
import proList from '../components/problem/proList'
import addSubject from '../components/problem/addSubject'
import impExpSubject from '../components/problem/impExpSubject'
import comList from '../components/CompetitionPractice/comList'
import creCom from '../components/CompetitionPractice/CreateCompetition'
import creCou from '../components/Course/CreateCourse'
import couList from '../components/Course/CourseList'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'HelloWorld',
      component: HelloWorld,
      redirect: 'das',
      children: [
        {
          path: 'das',
          name: 'Dashboard',
          component: Dashboard
        },
        {
          path: 'teacher',
          name: 'Teacher',
          component: Teacher
        },
        {
          path: 'student',
          name: 'Student',
          component: Student
        },
        {
          path: 'notice',
          name: 'Notice',
          component: Notice
        },
        {
          path: 'sysConfig',
          name: 'SysConfig',
          component: SysConfig
        },
        {
          path: 'judSer',
          name: 'JudSer',
          component: JudSer
        },
        {
          path: 'proList',
          name: 'ProList',
          component: proList
        },
        {
          path: 'add',
          name: 'addSubject',
          component: addSubject
        },
        {
          path: 'ies',
          name: 'impExpSubject',
          component: impExpSubject
        },
        {
          path: 'comList',
          name: 'comList',
          component: comList
        },
        {
          path: 'creCom',
          name: 'creCom',
          component: creCom
        },
        {
          path: 'creCou',
          name: 'creCou',
          component: creCou
        },
        {
          path: 'couList',
          name: 'couList',
          component: couList
        }
      ]
    }
  ]
})
